package fxification.test;

import javax.sql.DataSource;
import java.io.PrintWriter;
import fxification.java.FxSql;
import java.lang.UnsupportedOperationException;
import java.sql.Connection;

public class SimpleDataSource extends DataSource {
    public var username:String;
    public var password:String;
    public var url:String;

    override public function getLogWriter () : PrintWriter {
        throw new UnsupportedOperationException('Not implemented yet');
    }

    override public function getConnection () : Connection {
        FxSql.getConnection(null, url, username, password, null);
    }

    override public function setLoginTimeout (arg0 : Integer) : Void {
        throw new UnsupportedOperationException('Not implemented yet');
    }

    override public function getConnection (arg0 : String, arg1 : String) : Connection {
        throw new UnsupportedOperationException('Not implemented yet');
    }

    override public function getLoginTimeout () : Integer {
        throw new UnsupportedOperationException('Not implemented yet');
    }

    override public function setLogWriter (arg0 : PrintWriter) : Void {
        throw new UnsupportedOperationException('Not implemented yet');
    }
}